package com.textdisguise.www.TextDisguise.CaptchaService;

public class CaptchaServiceSoapProxy implements com.textdisguise.www.TextDisguise.CaptchaService.CaptchaServiceSoap {
  private String _endpoint = null;
  private com.textdisguise.www.TextDisguise.CaptchaService.CaptchaServiceSoap captchaServiceSoap = null;
  
  public CaptchaServiceSoapProxy() {
    _initCaptchaServiceSoapProxy();
  }
  
  public CaptchaServiceSoapProxy(String endpoint) {
    _endpoint = endpoint;
    _initCaptchaServiceSoapProxy();
  }
  
  private void _initCaptchaServiceSoapProxy() {
    try {
      captchaServiceSoap = (new com.textdisguise.www.TextDisguise.CaptchaService.CaptchaServiceLocator()).getCaptchaServiceSoap();
      if (captchaServiceSoap != null) {
        if (_endpoint != null)
          ((javax.xml.rpc.Stub)captchaServiceSoap)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
        else
          _endpoint = (String)((javax.xml.rpc.Stub)captchaServiceSoap)._getProperty("javax.xml.rpc.service.endpoint.address");
      }
      
    }
    catch (javax.xml.rpc.ServiceException serviceException) {}
  }
  
  public String getEndpoint() {
    return _endpoint;
  }
  
  public void setEndpoint(String endpoint) {
    _endpoint = endpoint;
    if (captchaServiceSoap != null)
      ((javax.xml.rpc.Stub)captchaServiceSoap)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
    
  }
  
  public com.textdisguise.www.TextDisguise.CaptchaService.CaptchaServiceSoap getCaptchaServiceSoap() {
    if (captchaServiceSoap == null)
      _initCaptchaServiceSoapProxy();
    return captchaServiceSoap;
  }
  
  public com.textdisguise.www.TextDisguise.CaptchaService.CaptchaImageWordModel getNewWord(com.textdisguise.www.TextDisguise.CaptchaService.ClientAuthModel cam) throws java.rmi.RemoteException{
    if (captchaServiceSoap == null)
      _initCaptchaServiceSoapProxy();
    return captchaServiceSoap.getNewWord(cam);
  }
  
  public boolean validateImageWord(com.textdisguise.www.TextDisguise.CaptchaService.ClientAuthModel cam, java.lang.String captchaImageGuid, java.lang.String word) throws java.rmi.RemoteException{
    if (captchaServiceSoap == null)
      _initCaptchaServiceSoapProxy();
    return captchaServiceSoap.validateImageWord(cam, captchaImageGuid, word);
  }
  
  public boolean abandonImageWord(com.textdisguise.www.TextDisguise.CaptchaService.ClientAuthModel cam, java.lang.String captchaImageGuid) throws java.rmi.RemoteException{
    if (captchaServiceSoap == null)
      _initCaptchaServiceSoapProxy();
    return captchaServiceSoap.abandonImageWord(cam, captchaImageGuid);
  }
  
  
}